package com.wzf.swagger;
import io.swagger.v3.oas.models.ExternalDocumentation;
import io.swagger.v3.oas.models.OpenAPI;
import io.swagger.v3.oas.models.info.Info;
import io.swagger.v3.oas.models.info.License;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
/**
 * TODO
 *Swagger配置类
 * @Date 2023/6/29 15:45
 */
@Configuration
public class SwaggerConfigruationSettings{
//    创建Docket对象
    @Bean
    public OpenAPI springShopOpenApi(){
        Info info = new Info()
                .title("整合springcloud全家桶")
                .version("v1.0")
                .description("前后端分离")
                .license(new License()
                        .name("Apache 2.0")
                        .url("http://222")
                );
 
        return new OpenAPI().info(info).externalDocs(new ExternalDocumentation()
                .description("doc").url("http://127.0.0.1:9001"));
    }
}